package co.yixiang.modules.shop.entity;

import java.math.BigDecimal;

import com.baomidou.mybatisplus.annotation.IdType;
import co.yixiang.common.entity.BaseEntity;

import java.util.Date;

import com.baomidou.mybatisplus.annotation.TableField;
import com.baomidou.mybatisplus.annotation.TableId;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Data;
import lombok.EqualsAndHashCode;

import java.util.Date;

/**
 * <p>
 * 认购订单表
 * </p>
 *
 * @author hisen
 * @since 2020-06-10
 */
@Data
@EqualsAndHashCode(callSuper = true)
@ApiModel(value = "YxInvestOrder对象", description = "认购订单表")
public class YxInvestOrder extends BaseEntity {

    private static final long serialVersionUID = 1L;

    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    @ApiModelProperty(value = "订单号")
    private String orderId;

    @ApiModelProperty(value = "认购金额")
    private Double price;

    @ApiModelProperty(value = "购物车id")
    private String cartId;

    private String adder;

    @ApiModelProperty(value = "添加时间")
    private Date addTime;

    @ApiModelProperty(value = "认购状态 0:锁定  1:未支付  2:已支付  3:投资中     4:已到期   9:取消投资")
    private Integer investStatus;

    @ApiModelProperty(value = "0 未退款 1 申请中 2 已退款")
    private Integer refundStatus;

    @ApiModelProperty(value = "退款时间")
    private Date refundReasonTime;

    @ApiModelProperty(value = "退款原因")
    private String refundReason;

    @ApiModelProperty(value = "不退款的理由")
    private String refundRefuseReason;

    @ApiModelProperty(value = "退款金额")
    private BigDecimal refundPrice;

    @ApiModelProperty(value = "认购者姓名")
    private String investName;

    @ApiModelProperty(value = "认购者电话")
    private String investPhone;

    @ApiModelProperty(value = "认购者身份号")
    private String investIdcard;

    @ApiModelProperty(value = "有效期 单位:月(取配置表)")
    private Integer expireMonth;

    @ApiModelProperty(value = "犹豫期 单位:自然日(取配置表)")
    private Integer hesitationDate;

    @ApiModelProperty(value = "支付状态  0 未支付   1已支付")
    private Integer paid;

    @ApiModelProperty(value = "支付时间")
    private Date payTime;

    @ApiModelProperty(value = "支付方式 1：前台支付  2：二维码扫码支付")
    private String payType;

    @ApiModelProperty(value = "结束时间")
    private Date endDate;

    @ApiModelProperty(value = "开始时间")
    private Date beignDate;

    @ApiModelProperty(value = "审核状态   0:未审核    1:审核通过   2:审核不通过")
    private Integer auditStatus;

    @ApiModelProperty(value = "审核人")
    private String auditor;

    @ApiModelProperty(value = "审核备注")
    private String auditRemark;

    @ApiModelProperty(value = "审核时间")
    private Date auditTime;

    @ApiModelProperty(value = "业务员名称")
    private String salesManName;

    @ApiModelProperty(value = "业务员id")
    private Integer salesManId;

    @ApiModelProperty(value = "买卖合同地址")
    private String contractUrl;

    @ApiModelProperty(value = "委托销售合同地址")
    private String saleContractUrl;

    @ApiModelProperty(value = "认购者银行卡号")
    private String investBankCard;

    @ApiModelProperty(value = "认购者银行卡所属银行")
    private String investBankName;

    @ApiModelProperty(value = "业务员头像")
    private String salesAvatar;

    @ApiModelProperty(value = "业务员手机号")
    private String salesPhone;

    @ApiModelProperty(value = "唯一id(md5加密)类似id")
    @TableField(value = "`unique`")
    private String unique;

 
    @ApiModelProperty(value = "银行卡图片地址")
    private String bankPicUrl;
    @ApiModelProperty(value = "身份证正面图片地址")
    private String idcardFrontPicUrl;
    @ApiModelProperty(value = "身份证反面图片地址")
    private String idcardReversePicUrl;
    @ApiModelProperty(value = "签名图片地址")
    private String signPicUrl;

    @ApiModelProperty(value = "购物车总商品数")
    private Integer totalNum;

    @ApiModelProperty(value = "支付机构代码  ORG_ALIPAY  支付宝     ORG_WEIXINPAY 微信   ORG_UNIONPAY 银联云闪付")
    private String payOrg;

    @ApiModelProperty(value = "支付单号")
    private String orderTradeNo;
}
